package com.qww;

public class Test01 {

    public static void main(String[] args) {
        System.out.println("start work...");
        while (condition()) {
            System.out.println("do working...");
        }
        System.out.println("end work...");

    }

    static boolean condition() {
        boolean result = Math.random() < 0.99;
        System.out.println("result = " + result);
        return result;
    }
}
